﻿
using BCCommon;
using BCCommon.Enums;
using BCData.Trading.SaleContractChecklist;
using BCDto.Trading.SaleContractChecklist;
using BCEntity.Trading.SaleContractChecklist;
using BCService.Utils;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace BCService.Trading.SaleContractChecklist
{
    /// <summary>
    /// 销售合同清单
    /// </summary>
    public interface ISaleContractChecklistService
    {
        #region  成员方法
        /// <summary>
        /// 是否存在此记录
        /// </summary>
        /// <param name="saleContractChecklistId">销售合同清单Id</param>
        bool Exists(long saleContractChecklistId);
        /// <summary>
        /// 是否存在该记录
        /// </summary>
        /// <param name="saleContractId">销售合同Id</param>
        /// <param name="saleGoodsId">销售商品Id</param>
        /// <returns></returns>
        bool Exists(long saleContractId, long saleGoodsId);
        /// <summary>
        /// 添加销售合同清单
        /// </summary>
        /// <param name="requestDto">销售合同清单信息</param>
        SaleContractChecklistDto Add(SaleContractChecklistRequestDto requestDto);
        /// <summary>
        /// 更新销售合同清单
        /// </summary>
        /// <param name="putDto">销售合同清单信息</param>
        SaleContractChecklistDto Update(SaleContractChecklistPutDto putDto);
        /// <summary>
        /// 删除销售合同清单
        /// </summary>
        /// <param name="saleContractChecklistId">销售合同清单Id</param>
        bool Delete(long saleContractChecklistId);
        /// <summary>
        /// 获取销售合同清单
        /// </summary>
        /// <param name="saleContractChecklistId">销售合同清单Id</param>
        SaleContractChecklistDto Get(long saleContractChecklistId);
        /// <summary>
        /// 获取销售合同清单列表
        /// </summary>
        /// <param name="saleContractId">销售合同Id</param>
        IEnumerable<SaleContractChecklistDto> GetList(long saleContractId);
        /// <summary>
        /// 获取销售合同清单分页列表
        /// </summary>
        /// <param name="saleContractId">销售合同Id</param>
        /// <param name="start">开始时间</param>
        /// <param name="end">结束时间</param>
        /// <param name="sortName">排序字段</param>
        /// <param name="ascending">升序</param>
        /// <param name="pageIndex">当前页码</param>
        /// <param name="pageSize">销售合同清单每页数据条数</param>
        PageableList<SaleContractChecklistDto> Query(long? saleContractId,DateTime? start, DateTime? end, string sortName, bool? ascending, int pageIndex, int pageSize);
        #endregion  成员方法
    }
}